-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add list itemLayoutAnimation documentation page and example #6279
Merged
MatiPl01
merged 14 commits into
main
from
@matipl01/improve-itemLayoutAnimation-docstring
Jul 23, 2024
Merged
Add list itemLayoutAnimation documentation page and example #6279
MatiPl01
merged 14 commits into
main
from
@matipl01/improve-itemLayoutAnimation-docstring
Jul 23, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MatiPl01
changed the title
Add information about lack of multi-column lists support
Add list itemLayoutAnimation documentation page and example
Jul 18, 2024
tjzel
requested changes
Jul 22, 2024
packages/docs-reanimated/docs/layout-animations/list-layout-animations.mdx
Outdated
Show resolved
Hide resolved
packages/docs-reanimated/docs/layout-animations/list-layout-animations.mdx
Outdated
Show resolved
Hide resolved
apps/common-app/src/examples/LayoutAnimations/ListItemLayoutAnimation.tsx
Outdated
Show resolved
Hide resolved
apps/common-app/src/examples/LayoutAnimations/ListItemLayoutAnimation.tsx
Outdated
Show resolved
Hide resolved
apps/common-app/src/examples/LayoutAnimations/ListItemLayoutAnimation.tsx
Outdated
Show resolved
Hide resolved
apps/common-app/src/examples/LayoutAnimations/ListItemLayoutAnimation.tsx
Outdated
Show resolved
Hide resolved
packages/docs-reanimated/docs/layout-animations/list-layout-animations.mdx
Show resolved
Hide resolved
tjzel
reviewed
Jul 22, 2024
apps/common-app/src/examples/LayoutAnimations/ListItemLayoutAnimation.tsx
Outdated
Show resolved
Hide resolved
…imations.mdx Co-authored-by: Tomasz Żelawski <40713406+tjzel@users.noreply.github.com>
Co-authored-by: Tomasz Żelawski <40713406+tjzel@users.noreply.github.com>
…imations.mdx Co-authored-by: Tomasz Żelawski <40713406+tjzel@users.noreply.github.com>
tjzel
approved these changes
Jul 23, 2024
packages/docs-reanimated/docs/layout-animations/list-layout-animations.mdx
Outdated
Show resolved
Hide resolved
…imations.mdx Co-authored-by: Tomasz Żelawski <40713406+tjzel@users.noreply.github.com>
This was referenced Sep 24, 2024
This was referenced Oct 1, 2024
This was referenced Oct 3, 2024
This was referenced Oct 4, 2024
This was referenced Oct 5, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds example usage of
itemLayoutAnimation
prop to the example app and docs page with example recording and details.Example image of the added docs page
Related context
Related issue: #6278
Support for
multi-column
lists seems to be impossible to implement. react-native adds additional wrapper component for each row and re-renders list items in different rows when new items are added or items are removed from the list. Because the parent of list items changes and the layout animation cannot be applied to the wrapper that is added to list rows, layout animations won't work for lists with multiple columns.At least, I didn't come up with any valid solution.
PR that adds support for
FlatList
items animations: #2674What react-native does for mutli-column lists: https://github.com/facebook/react-native/blob/2098806c2207f376027184329a7285913ef8d090/packages/react-native/Libraries/Lists/FlatList.js#L643